1. Field of the Invention
The invention relates generally to a remote copy system using a storage system, and especially to an asynchronous remote copy system having a function for swapping the roles of a main site and a remote site between a first storage system and a second storage system included in the remote copy system. In the description below, this function will be sometimes referred to as a swap function.
2. Description of Related Art
In database systems handling a large amount of data, such as those used in a data center, data is often managed using a storage system that is provided separately from a host system. A disk array system is a well known example of such a storage system.
The disk array system manages a lot of disk drives arranged in an array via RAID (Redundant Array of Inexpensive Disks) management. Many disk drives provide a physical storage area, and at least one logical unit is formed in the physical storage area. This logical unit is provided to a host system. The host system recognizes the logical unit as one physical device and data-accesses the logical unit.
In such a storage system, measures are taken for securely protecting data in case of disasters or similar. For example, JP2005-293469 A discloses a system capable of enhancing fault tolerance by remote-copying data written to a copy-source volume in a primary storage control apparatus located at a main site to a copy-destination volume in a secondary storage control apparatus located at a remote site, so as to realize data duplication.
Such remote copying includes two types: synchronous remote copy, which synchronously processes host IO from a host in the main site to the primary storage control apparatus and remote copy IO from the primary storage control apparatus to the secondary storage control apparatus; and asynchronous remote copy, which asynchronously processes the host IO and the remote copy IO.
In the asynchronous remote copy, the primary storage control apparatus fixes difference data in the copy-source volume on a predetermined cycle (e.g., every five minutes), and transfers the difference data to the copy-destination volume in the secondary storage control apparatus once every cycle. In the description below, in some situations, the copy-source volume will be referred to as a primary volume and the copy-destination volume will be referred to as a secondary volume.
A system that executes the synchronous remote copy synchronously double-writes write data from the host to the primary volume and to the secondary volume. Accordingly, when the swap function is requested by a user, the swap function can be realized by promoting the secondary volume at the remote site to a primary volume while changing the primary volume at the main site to a secondary volume to swap the roles of the remote site and the main site.
On the other hand, in a related art asynchronous remote copy system that does not have such a swap function, data update in the primary volume at the main site is reflected in the secondary volume several minutes or several tens of minutes later. Due to this arrangement, the secondary volume is in an unfixed state while the asynchronous remote copy is being executed, so the secondary volume cannot be promoted as is to the primary volume when a command for executing the swap function is issued to the remote copy system.
In order to realize the swap function in the asynchronous remote copy system, the data image of the secondary volume has to be restored to its status before the current asynchronous remote copy cycle, and the primary volume at the main site has to be matched with the secondary volume at the remote site; in short, both of the volumes have to be temporarily synchronized to realize the swap function.
Here, when copying all data in the secondary volume to the primary volume, it will take a long time to complete the copy, and in addition, a large communication load will be applied to the communication line connecting the main site and the remote site to each other.